<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <!-- 重置样式 -->
    <link rel="stylesheet" href="/css/reset.css">
    <!-- 公共样式 -->
    <link rel="stylesheet" href="/css/base.css">
    <!-- 当前主页样式 -->
    <link rel="stylesheet" href="/css/header.css">
    <!-- 图标库 -->
    <link rel="stylesheet" href="/iconfont/iconfont.css">
</head>

<body>
<!-- 顶部导航条 -->
<header>
    <div class="headbar">
        <!-- 创建内部容器 -->
        <div class="topbar w clearfix">
            <!-- 左侧的导航 -->
            <nav>
                <ul class="service">
                    <li>
                        <a href="/">居逸商城</a>
                        <span>|</span>
                    </li>
                </ul>
            </nav>
            <!-- 购物车 -->
            <div class="buy-cart fr">
                <a href="/cart/index">
                    <i class="iconfont icon-gouwuche"></i>
                    <span>购物车</span>
                    <span>(0)</span>
                </a>
                <!-- 下拉购物车 -->
                <div class="cart-menu">
                    购物车中还没有商品,赶紧选购吧!
                </div>
            </div>

            <!-- 用户登录注册 -->
            <ul class="header-info fr" th:if="${session.CURRENT_MEMBER == null}">
                <li><a href="/login">登录</a><span>|</span></li>
                <li><a href="/register">注册</a><span>|</span></li>
            </ul>

            <ul class="header-info fr" th:if="${session.CURRENT_MEMBER != null}">
                <li><a href="/member/personal" th:text="${session.CURRENT_MEMBER.nickname}"></a><span>|</span></li>
            </ul>

        </div>
    </div>
</header>

    <script src="/js/jquery.min.js"></script>
    <script src="/js/header.js"></script>
    <script src="/js/lay-module/common/common.js"></script>
</body>
</html>